﻿using System.Collections.Generic;
using PagingControl.JSon;

namespace JQueryPractice
{
    public class ListSorter
    {

        public void Sort(List<Person> persons)
        {
            persons.Sort(Comparison);
            var array = persons.ToArray();
        }

        private int Comparison(Person personX,Person personY)
        {
            return personX.Name.CompareTo(personY.Name);
        }
    }
}